export default {
  data() {
    return {
      listConfig: {
        columns: [
          {
            prop: 'distributionNo',
            label: '铺货订单编号'
          },
          {
            prop: 'createTime',
            label: '提交时间'
          },
          {
            prop: 'receiver',
            label: '发货人'
          },
          {
            prop: 'storeName',
            label: '门店'
          },
          {
            prop: 'totalAmount',
            label: '订单金额'
          },
          {
            prop: 'requiredQty',
            label: '总件数'
          },
          {
            prop: 'channelCode',
            label: '订单来源'
          },
          {
            prop: 'status',
            label: '订单状态'
          }
        ],
        opts: {
          width: 240,
          custom: [
            {
              text: '查看订单',
              size: 'small',
              emit: 'go-detail'
            },
            {
              text: '订单跟踪',
              size: 'small',
              emit: 'go-trace'
            },
            {
              text: '删除订单',
              size: 'small',
              emit: 'delete-order',
              availability: (rowItem) => { return false }
            }
          ]
        }
      }
    }
  },
  methods: {
    detail(id) {
      this.$router.push({
        path: '/orders/door/detail',
        query: { id }
      })
    },
    trace(id) {
      this.$router.push({
        path: '/orders/door/trace',
        query: { id }
      })
    },
    deleteOrder(id) {

    }
  }
}
